package com.wgy.day12.Scanner键盘输入;

import java.util.Scanner;

/**
 * Created by pc on 2020/11/7 22:43
 * Description: LearningJava
 */
public class Demo03ScannerMax {

    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        int a = sc.nextInt();
        int b = sc.nextInt();
        int c = sc.nextInt();
//第一种方法  转化为数组后比较
        int[] array = {a, b, c};
        int max = array[0];
        for (int i = 1; i < array.length; i++) {
            if (array[i] > max) {
                max = array[i];
            }
        }
        System.out.println(max);
        //第二种方法  两两比较
        int temp = a > b ? a : b;
        int max1 = temp > c ? temp : c;
        System.out.println(max1);
    }


}
